<template>
  <a-modal
    title="抖音订单核销"
    :width="720"
    :visible="visible"
    @ok="handleOk"
    @cancel="hide"
    :centered="true"
    okText="确定"
  >
    <a-form >
      <a-form-item label="抖音核销券号" style="display: flex">
        <div style="display: flex;align-items: center">
          <a-input v-model="num" placeholder="请填写抖音核销券号" style="margin-right: 20px;width: 500px"></a-input>
        </div>
      </a-form-item>
    </a-form>

  </a-modal>
</template>
<script>
import { clothesDouyinVerify } from "@/api/clothes";
export default {
  data() {
    return {
      visible: false,
      num: '',
    }
  },
  methods: {
    show() {
      this.visible = true;
    },
    hide() {
      this.visible = false;
    },
    handleOk() {
      /*this.$router.push({
        name: 'douyinList',
        query: {
          verify_id: 9.9,
          price: 9.9,
        }
      })*/
      const params = {
        encrypted_data: this.num
      }
      clothesDouyinVerify(params).then((res) => {
        this.num = '';
        this.hide();
        this.$router.push({
          name: 'douyinList',
          query: {
            //verify_id: res.data.verify_id,
            price: res.data.price,
            encrypted_data: res.data.encrypted_data
          }
        })
      })
    }
  },
}
</script>
<style scoped lang="less">
/deep/ .ant-radio-group {
  width: 100%;
}
</style>